using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration;

namespace ConsoleApplication11.Models.Mapping
{
    public class PCI_historyMap : EntityTypeConfiguration<PCI_history>
    {
        public PCI_historyMap()
        {
            // Primary Key
            this.HasKey(t => t.PCI_history_id);

            // Properties
            this.Property(t => t.Patient_id)
                .HasMaxLength(20);

            this.Property(t => t.create_by)
                .HasMaxLength(20);

            this.Property(t => t.update_by)
                .HasMaxLength(20);

            this.Property(t => t.operation_doctor_name)
                .HasMaxLength(10);

            this.Property(t => t.operation_assistant_name)
                .HasMaxLength(50);

            this.Property(t => t.operationing_complication)
                .HasMaxLength(100);

            this.Property(t => t.contrast_agent_name)
                .HasMaxLength(50);

            this.Property(t => t.PCI_before_treatment_effect)
                .HasMaxLength(500);

            this.Property(t => t.PCI_before_treatment_reaction)
                .HasMaxLength(200);

            // Table & Column Mappings
            this.ToTable("PCI_history");
            this.Property(t => t.PCI_history_id).HasColumnName("PCI_history_id");
            this.Property(t => t.Patient_id).HasColumnName("Patient_id");
            this.Property(t => t.Follow_up_id).HasColumnName("Follow_up_id");
            this.Property(t => t.create_time).HasColumnName("create_time");
            this.Property(t => t.create_by).HasColumnName("create_by");
            this.Property(t => t.update_time).HasColumnName("update_time");
            this.Property(t => t.update_by).HasColumnName("update_by");
            this.Property(t => t.emergency_PCI).HasColumnName("emergency_PCI");
            this.Property(t => t.coronary_angiography_left).HasColumnName("coronary_angiography_left");
            this.Property(t => t.coronary_angiography_right).HasColumnName("coronary_angiography_right");
            this.Property(t => t.coronary_angiography_balance).HasColumnName("coronary_angiography_balance");
            this.Property(t => t.target_lesion_position_LAD).HasColumnName("target_lesion_position_LAD");
            this.Property(t => t.target_lesion_position_LCX).HasColumnName("target_lesion_position_LCX");
            this.Property(t => t.target_lesion_position_RCA).HasColumnName("target_lesion_position_RCA");
            this.Property(t => t.target_lesion_position_LM).HasColumnName("target_lesion_position_LM");
            this.Property(t => t.target_lesion_position_intermediate).HasColumnName("target_lesion_position_intermediate");
            this.Property(t => t.target_lesion_position_arterial_bridge).HasColumnName("target_lesion_position_arterial_bridge");
            this.Property(t => t.target_lesion_position_vein_bridge).HasColumnName("target_lesion_position_vein_bridge");
            this.Property(t => t.target_lesion_position_deformity_coronary_artery).HasColumnName("target_lesion_position_deformity_coronary_artery");
            this.Property(t => t.diagnostic_results_one_branch_lesion).HasColumnName("diagnostic_results_one_branch_lesion");
            this.Property(t => t.diagnostic_results_two_branch_lesion).HasColumnName("diagnostic_results_two_branch_lesion");
            this.Property(t => t.diagnostic_results_three_branch_lesion).HasColumnName("diagnostic_results_three_branch_lesion");
            this.Property(t => t.diagnostic_results_LMT).HasColumnName("diagnostic_results_LMT");
            this.Property(t => t.diagnostic_results_bifurcation_lesions).HasColumnName("diagnostic_results_bifurcation_lesions");
            this.Property(t => t.diagnostic_results_CTO).HasColumnName("diagnostic_results_CTO");
            this.Property(t => t.diagnostic_results_thrombosis_lesions).HasColumnName("diagnostic_results_thrombosis_lesions");
            this.Property(t => t.operation_doctor_name).HasColumnName("operation_doctor_name");
            this.Property(t => t.operation_assistant_name).HasColumnName("operation_assistant_name");
            this.Property(t => t.PCI_approach_femoral_artery).HasColumnName("PCI_approach_femoral_artery");
            this.Property(t => t.PCI_approach_radial_artery).HasColumnName("PCI_approach_radial_artery");
            this.Property(t => t.PCI_approach_brachial_artery).HasColumnName("PCI_approach_brachial_artery");
            this.Property(t => t.PCI_approach_other).HasColumnName("PCI_approach_other");
            this.Property(t => t.PCI_Target_vessel_LM).HasColumnName("PCI_Target_vessel_LM");
            this.Property(t => t.PCI_Target_vessel_LM_LAD).HasColumnName("PCI_Target_vessel_LM_LAD");
            this.Property(t => t.PCI_Target_vessel_LAD).HasColumnName("PCI_Target_vessel_LAD");
            this.Property(t => t.PCI_Target_vessel_LM_LCX).HasColumnName("PCI_Target_vessel_LM_LCX");
            this.Property(t => t.PCI_Target_vessel_LCX).HasColumnName("PCI_Target_vessel_LCX");
            this.Property(t => t.PCI_Target_vessel_RCA).HasColumnName("PCI_Target_vessel_RCA");
            this.Property(t => t.PCI_Target_vessel_LM_intermediate).HasColumnName("PCI_Target_vessel_LM_intermediate");
            this.Property(t => t.PCI_Target_vessel_intermediate).HasColumnName("PCI_Target_vessel_intermediate");
            this.Property(t => t.PCI_Target_vessel_arterial_bridge).HasColumnName("PCI_Target_vessel_arterial_bridge");
            this.Property(t => t.PCI_Target_vessel_vein_bridge).HasColumnName("PCI_Target_vessel_vein_bridge");
            this.Property(t => t.PCI_Target_vessel_deformity_coronary_artery).HasColumnName("PCI_Target_vessel_deformity_coronary_artery");
            this.Property(t => t.PCI_record_LMT_seg6).HasColumnName("PCI_record_LMT_seg6");
            this.Property(t => t.PCI_record_LMT_seg7).HasColumnName("PCI_record_LMT_seg7");
            this.Property(t => t.PCI_record_LMT_seg8).HasColumnName("PCI_record_LMT_seg8");
            this.Property(t => t.PCI_record_LMT_seg9Stenosis).HasColumnName("PCI_record_LMT_seg9Stenosis");
            this.Property(t => t.PCI_record_LMT_stent).HasColumnName("PCI_record_LMT_stent");
            this.Property(t => t.PCI_record_LCX_seg6).HasColumnName("PCI_record_LCX_seg6");
            this.Property(t => t.PCI_record_LCX_seg7).HasColumnName("PCI_record_LCX_seg7");
            this.Property(t => t.PCI_record_LCX_seg8).HasColumnName("PCI_record_LCX_seg8");
            this.Property(t => t.PCI_record_LCX_seg9Stenosis).HasColumnName("PCI_record_LCX_seg9Stenosis");
            this.Property(t => t.PCI_record_LCX_stent).HasColumnName("PCI_record_LCX_stent");
            this.Property(t => t.PCI_record_RCA_seg11).HasColumnName("PCI_record_RCA_seg11");
            this.Property(t => t.PCI_record_RCA_seg12).HasColumnName("PCI_record_RCA_seg12");
            this.Property(t => t.PCI_record_RCA_seg13).HasColumnName("PCI_record_RCA_seg13");
            this.Property(t => t.PCI_record_RCA_seg14).HasColumnName("PCI_record_RCA_seg14");
            this.Property(t => t.PCI_record_RCA_seg1).HasColumnName("PCI_record_RCA_seg1");
            this.Property(t => t.PCI_record_RCA_seg2).HasColumnName("PCI_record_RCA_seg2");
            this.Property(t => t.PCI_record_RCA_seg3).HasColumnName("PCI_record_RCA_seg3");
            this.Property(t => t.PCI_record_RCA_seg4Stenosis).HasColumnName("PCI_record_RCA_seg4Stenosis");
            this.Property(t => t.PCI_record_RCA_stent).HasColumnName("PCI_record_RCA_stent");
            this.Property(t => t.operationing_complication).HasColumnName("operationing_complication");
            this.Property(t => t.contrast_agent_name).HasColumnName("contrast_agent_name");
            this.Property(t => t.contrast_agent_dose).HasColumnName("contrast_agent_dose");
            this.Property(t => t.after_operation_ToGood).HasColumnName("after_operation_ToGood");
            this.Property(t => t.after_operation_Dead).HasColumnName("after_operation_Dead");
            this.Property(t => t.after_operation_Complication).HasColumnName("after_operation_Complication");
            this.Property(t => t.Is_Past_PCI_Treatment).HasColumnName("Is_Past_PCI_Treatment");
            this.Property(t => t.PCI_before_treatment_effect).HasColumnName("PCI_before_treatment_effect");
            this.Property(t => t.PCI_before_treatment_reaction).HasColumnName("PCI_before_treatment_reaction");
        }
    }
}
